home *** CD-ROM | disk | FTP | other *** search
/ Languguage OS 2 / Languguage OS II Version 10-94 (Knowledge Media)(1994).ISO / gnu / dejagnu.lha / dejagnu-1.0.1 / tcl / README < prev    next >
Text File  |  1993-02-14  |  11KB  |  250 lines

  1. Tcl
  2.  
  3. by John Ousterhout
  4. University of California at Berkeley
  5. ouster@cs.berkeley.edu
  6.  
  7. 1. Introduction
  8. ---------------
  9.  
  10. This directory contains the sources and documentation for Tcl, an
  11. embeddable tool command language.  The information here corresponds
  12. to release 6.7.
  13.  
  14. For an introduction to the facilities provided by Tcl, your best bet
  15. is to retrieve the partial draft of the Tcl/Tk book, which is available
  16. for FTP from the standard Tcl/Tk release directories.  Another possibility
  17. is to see the paper ``Tcl:  An Embeddable Command Language'', in the
  18. Proceedings of the 1990 Winter USENIX Conference.  A copy of that paper
  19. is also available in Postscript form in the distribution directory.
  20. However, the paper corresponds to a much earlier version of Tcl
  21. (approximately version 3.0), so some details of the paper may not be
  22. correct anymore and there are many new features not described in the
  23. paper.
  24.  
  25. 2. What's New Or Different In This Release
  26. ------------------------------------------
  27.  
  28. Tcl 6.7 contains just a few changes to fix a few minor configuration
  29. and installation problems with Tcl 6.6.  The 6.6 release also contains
  30. only minor changes and should not break any existing Tcl scripts or C
  31. programs.  Refer to the "changes" file for complete details on all the
  32. changes.  Below is a list of the most significant changes in the 6.6
  33. release:
  34.  
  35. (a) Added "elseif" support to the "if" command.
  36.  
  37. (b) Changed "puts" and "read" to support initial "-nonewline" switch
  38. instead of additional "nonewline" argument.  The old form is still
  39. accepted but it's obsolete and shouldn't be used any more.  Puts
  40. now allows the file argument to be omitted, in which case it
  41. defaults to stdout.
  42.  
  43. (c) Fixed several bugs in 6.5 related to detecting the ends of long
  44. commands.
  45.  
  46. (d) Improved the Makefile (eliminated -f switch to cp, improved
  47. installation, etc.)
  48.  
  49. Here are a few of the most important changes that appeared in the earlier
  50. 6.5 release.  As with 6.6 and 6.7, the 6.5 release should not break any
  51. existing Tcl scripts or C programs.
  52.  
  53. (a) The "unknown" procedure has been improved in several ways:
  54.     - It now allows nested auto-loads, so that the auto-load of one file
  55.       can trigger additional auto-loads, as long as there are no cycles.
  56.     - It now emulates csh's "!!", "!<num>", and "^<old>^<new>" history
  57.       substitutions.
  58.     - Auto_reset now deletes all auto-loaded procedures so that they'll
  59.       be reloaded from disk the next time they're invoked.  This makes
  60.       script debugging easier.
  61.  
  62. (b) The installation setup has been modified (improved?) in several ways:
  63.     - The Makefile checks to be sure that config has been run and won't
  64.       compile the program if it hasn't.
  65.     - The TCL_LIBRARY environment variable can be used to override the
  66.       compiled-in location of the library directory.
  67.     - The "config" script is now cleverer about figuring out which switches
  68.       to pass to nm.
  69.     - Manual entries have been renamed to use ".3" and ".n" extensions.
  70.     - The Makefile includes a "make install" target.
  71.     - Introductory documents are no longer part of the release;  they have
  72.       to be retrieved separately.
  73.  
  74. (c) There's a new command, "info complete", plus a C procedure
  75.     Tcl_CommandComplete, which provide some help in parsing Tcl commands.
  76.  
  77. 3. Documentation
  78. ----------------
  79.  
  80. The "doc" subdirectory contains a complete set of manual entries for
  81. Tcl.  Files with extension ".3" are for C library procedures provided
  82. by Tcl;  files with extension ".n" describe the core Tcl commands. The
  83. file "doc/Tcl.n" gives an overall description of the Tcl language and
  84. describes the core Tcl commands (most of this material is now available
  85. in a more palatable form in the book draft).  To print any of the man
  86. pages, cd to the "doc" directory and invoke your favorite variant of
  87. troff using the normal -man macros, for example
  88.  
  89.         ditroff -man <file>
  90.  
  91. where <file> is the name of the man page you'd like to print.
  92.  
  93. 4. Machines supported
  94. ---------------------
  95.  
  96. If you follow the directions below, this release should compile
  97. and run on the following configurations either "out of the box"
  98. or with only trivial changes:
  99.  
  100.     - Sun-3's, Sun-4's, SPARCstation-1's and SPARCstation-2's running
  101.       many variants of SunOS, such as 4.1.
  102.     - DECstation-3100's and DECstation-5000's running many versions of
  103.       Ultrix, such as 2.0 and 4.2.
  104.     - DEC VAXes running many versions of Ultrix or BSD UNIX. 
  105.     - Intel 386 based systems running SCO Unix 3.2v2.
  106.     - Intel 386 based systems running SCO Xenix 2.3.3.
  107.     - Intel 386 based systems running Bell-Tech (now Intel) Unix 3.2.0.
  108.     - Silicon Graphics systems running IRIX 4.0.
  109.     - Various H-P machines running versions of HP-UX such as 7.05
  110.     - Sequent Symmetry running versions of Dynix/ptx such as v1.2.4
  111.     - AT&T 368 machines running SVR4 2.0.1
  112.  
  113. If you find problems running Tcl on any of the above configurations,
  114. please let me know.  Also, if you are able to compile Tcl and run the
  115. test suite successfully on configurations not listed above, please
  116. let me know and tell me what changes, if any, you needed to make to
  117. do it.  I'd like to keep the above list up-to-date and continue to
  118. improve the portability of Tcl.
  119.  
  120. Tcl can be used on many other configurations with only a few
  121. modifications.  The file "porting.notes" contains information sent to
  122. me about what it took to get Tcl to run on various other configurations.
  123. I make no guarantees that this information is accurate or complete, but
  124. you may find it useful.  If you get Tcl running on a new configuration,
  125. I'd be happy to receive new information to add to "porting.notes".
  126.  
  127. 5. Compiling Tcl
  128. ----------------
  129.  
  130. To compile Tcl on any of the configurations listed above, or systems
  131. similar to them, do the following:
  132.  
  133.     (a) If your system isn't one of the ones listed above, look in the
  134.         file "porting.notes" to see if your system is listed there.  This
  135.     file contains additional notes on getting Tcl to run on various
  136.     other systems.
  137.  
  138.     (b) Edit the "set" commands at the beginning of the file "config"
  139.         if necessary to correspond to your system configuration (they
  140.     should already be right for most versions of Unix).
  141.  
  142.     (c) Configure the Makefile in this directory according to the
  143.         instructions at the beginning of the file.  In particular, if
  144.     you're not going to install the library in the suggested place
  145.     (/usr/local/lib/tcl) you need to reset the TCL_LIBRARY variable.
  146.     You may also want to change CC, CFLAGS, etc.
  147.  
  148.     (d) Type "./config" to invoke Tcl's auto-configuration script.  This
  149.         script pokes around in your system to see if certain almost-standard
  150.     things are missing (header files, library procedures, etc.); if
  151.     your system doesn't seem to have them, it configures Tcl to use
  152.     its own copies of these things instead (Tcl's copies are kept in
  153.     the "compat" subdirectory).  Config prints out messages for all
  154.     the substitutions it made.  You can ignore any of the messages
  155.     unless they say "ERROR!!", in which case something is fundamentally
  156.     wrong and the script couldn't handle your system configuration.
  157.  
  158.     If Tcl isn't able to configure itself to compile on your machine,
  159.         then I suggest the following approach:
  160.         - Start again with a fresh copy of the distribution.
  161.         - Set the #defines that appear at the very front of
  162.           tclUnix.h (before the first #include) to correspond
  163.           to your system.
  164.         - Create a file "configured" in this directory, so that the
  165.           Makefile won't generate errors.
  166.         - If things don't compile or don't link, then you may need
  167.           to copy some of the .c or .h files from the "compat"
  168.           directory into the main Tcl directory to compensate for
  169.           files missing from your system.  Modify the COMPAT_OBJS
  170.           definition in Makefile to include a .o name for each of
  171.           the .c files that you copied up from the compat directory.
  172.  
  173.     (e) Type "make" to compile the library.  This will create the Tcl
  174.     library in "libtcl.a".  The Makefile should work without any
  175.     modifications but you may wish to personalize it, e.g. to
  176.     turn on compiler optimization.
  177.  
  178.     (f) Type "make install" to install Tcl binaries and script files in
  179.         standard places.  You'll need write permission on /usr/local to
  180.     do this.  See the Makefile for details on where things get
  181.     installed.
  182.  
  183.     (g) Type "make tclTest", which will create a simple test program that
  184.     you can use to try out the Tcl facilities.  TclTest is just a
  185.     main-program sandwich around the Tcl library.  It reads standard
  186.     input until it reaches the end of a line where parentheses and
  187.     backslashes are balanced, then sends everything it's read to the
  188.     Tcl interpreter.  When the Tcl interpreter returns, tclTest prints
  189.     the return value or error message.  TclTest defines a few other
  190.     additional commands, most notably:
  191.     
  192.             echo arg arg ...
  193.     
  194.     The "echo" command prints its arguments on standard output,
  195.     separated by spaces.
  196.  
  197. 6. Test suite
  198. -------------
  199.  
  200. There is a relatively complete test suite for all of the Tcl core in
  201. the subdirectory "tests".  To use it just type "make test" in this
  202. directory.  You should then see a printout of the test files processed.
  203. If any errors occur, you'll see a much more substantial printout for
  204. each error.  Tcl should pass the test suite cleanly on all of the
  205. systems listed in Section 4.  See the README file in the "tests"
  206. directory for more information on the test suite.
  207.  
  208. 7. Compiling on non-UNIX systems
  209. --------------------------------
  210.  
  211. The Tcl features that depend on system calls peculiar to UNIX (stat,
  212. fork, exec, times, etc.) are now separate from the main body of Tcl,
  213. which only requires a few generic library procedures such as malloc
  214. and strcpy.  Thus it should be relatively easy to compile Tcl for
  215. these machines, although a number of UNIX-specific commands will
  216. be absent (e.g.  exec, time, and glob).  See the comments at the
  217. top of Makefile for information on how to compile without the UNIX
  218. features.
  219.  
  220. 8. Special thanks
  221. -----------------
  222.  
  223. Mark Diekhans and Karl Lehenbauer of Santa Cruz Operation deserve special
  224. thanks for all their help during the development of Tcl 6.0.  Many of the
  225. new features in Tcl 6.0 were inspired by an enhanced version of Tcl 3.3
  226. called Extended Tcl 4.0, which was created by Mark, Karl, and Peter
  227. da Silva.  Mark and Karl explained these features to me and provided
  228. excellent (and challenging) feedback during the 6.0 development process.
  229. They were also a great help in finding and fixing portability problems.
  230. Without their ideas and assistance Tcl 6.0 would be much less powerful.
  231.  
  232. 9. Support
  233. ----------
  234.  
  235. There is no official support organization for Tcl, and I can't promise
  236. to provide much hand-holding to people learning Tcl.  However, I'm very
  237. interested in receiving bug reports and suggestions for improvements.
  238. Bugs usually get fixed quickly (particularly if they are serious), but
  239. enhancements may take a while and may not happen at all unless there
  240. is widespread support for them.
  241.  
  242. 10. Tcl newsgroup
  243. -----------------
  244.  
  245. There is a network news group "comp.lang.tcl" intended for the exchange
  246. of information about Tcl, Tk, and related applications.  Feel free to use
  247. this newsgroup both for general information questions and for bug reports.
  248. I read the newsgroup and will attempt to fix bugs and problems reported
  249. to it.
  250.